The QuickTime VR Manager provides functions that you can use to get the physical viewing limits of a movie and to get and set a movie's constraints.
You can use the QTVRGetViewingLimits function to get the current viewing limits of a QuickTime VR movie.
OSErr QTVRGetViewingLimits (
QTVRInstanceqtvr,
UInt16kind,
float*minValue,
float*maxValue);
The QTVRGetViewingLimits function returns, in the floating-point values pointed to by the minValue and maxValue parameters, the current minimum and maximum values for angles whose type is specified by the kind parameter.
The maximum field of view of a panoramic node can be limited by the size of the back buffer and the current aspect ratio of the movie's graphics world.
The values returned by QTVRGetViewingLimits are unaffected by the current control settings.
QTVRGetViewingLimits returns information about the physical viewing limits of a panorama or object. To get information about the current viewing constraints, use QTVRGetConstraints .
You can use the QTVRGetConstraintStatus function to get the set of constraints active for the current view.
UInt32 QTVRGetConstraintStatus (QTVRInstanceqtvr);
The QTVRGetConstraintStatus function returns, as its function result, a long integer whose bits encode the constraints currently active for the QuickTime VR movie specified by the qtvr parameter. See "Viewing Constraints" for a description of the available constraints.
The values returned by QTVRGetConstraintStatus are unaffected by the current control settings.
You can use the QTVRGetConstraints function to get the current constraints of a movie.
OSErr QTVRGetConstraints (
QTVRInstance qtvr,
UInt16kind,
float*minValue,
float*maxValue);
The QTVRGetConstraints function returns, in the floating-point values pointed to by the minValue and maxValue parameters, the current minimum and maximum constraints of the type specified by the kind parameter.
The values returned by QTVRGetConstraints are unaffected by the current control settings.
You can use the QTVRSetConstraints function to set the constraints of a movie.
OSErr QTVRSetConstraints (
QTVRInstanceqtvr,
UInt16kind,
floatminValue,
floatmaxValue);
The QTVRSetConstraints function sets the minimum and maximum constraints of the type specified by the kind parameter to the values specified by the minValue and maxValue parameters. Note that when you want to specify a pan angle constraint, the minValue and maxValue parameters should be specified so that a clockwise sweep from minValue to maxValue selects the desired angular expanse. For example, to constrain panning in the 90-degree expanse that spreads out 45 degrees on each side of the pan angle 0 degrees, you should set the minValue parameter to 315 degrees and the maxValue parameter to 45 degrees. Similarly, to constrain panning in the remaining 270-degree expanse, you should set the minValue parameter to 45 degrees and the maxValue parameter to 315 degrees.
The values passed to QTVRSetConstraints are unaffected by the current control settings.
Use QTVRGetConstraints to get a movie's minimum and maximum constraints.
| Previous | Chapter Contents | Chapter Top | Next |